<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<script type="text/javascript">
	var pageNo = $("#cpageNo").val();
	function selectPage(){
		var value = $("#selectPage").val();
		goPage(value)
	}
	$("#selectPage").val(pageNo);
	function jumpToPage(obj){
		goPage(obj.value);
	}
</script>
<div class="pageDiv">

	当前第${page.currentPage}页 
    <c:if test="${page.currentPage == 1}">
    	<input type="button" value="首页" disabled="disabled"/>
    	<input type="button" value="上一页" disabled="disabled"/>
    </c:if>
    <c:if test="${page.currentPage != 1}">
	    <input type="button" value="首页" onclick="goPage(1)"/>
	    <input type="button" value="上一页" onclick="goPage(${page.currentPage-1})"/>
    </c:if>
    <c:if test="${page.currentPage == page.pageCount }">
	    <input type="button" value="下一页" disabled="disabled"/>
	    <input type="button" value="末页" disabled="disabled"/>
    </c:if>
    <c:if test="${page.currentPage != page.pageCount }">
	    <input type="button" value="下一页" onclick="goPage(${page.currentPage+1})"/>
	    <input type="button" value="末页" onclick="goPage(${page.pageCount})"/>
    </c:if>
    
      共${page.pageCount }页 | 共${page.totalCount }条记录 &nbsp;第
    <select onchange="jumpToPage(this)">
	    <c:forEach var="p" begin="1" end="${page.pageCount }">
	    	<c:if test="${p==page.currentPage }"><option selected>${p}</option></c:if>
	    	<c:if test="${p!=page.currentPage }"><option>${p}</option></c:if>
	    </c:forEach>
    </select>页
</div>